Fundamentally, Microsoft Learning Components implements a runtime for e-learning packages. This section explains what e-learning package are, and describes the basic operations that MLC performs on them. See StoredLearningSession to learn how to execute learning packages.
In the context of Microsoft Learning Components, a package is a file containing e-learning content, in one of the following formats:
SCORM (Sharable Content Object Reference Model), is an e-learning content standard published by Advanced Distributed Learning.
These e-learning formats are interpreted by SLK at run-time, i.e. when a user "execute" e-learning content. Examples:
Unlike SharePoint Learning Kit, MLC does not support non-e-learning documents.
Microsoft Learning Components includes several classes, called package readers, that all derive from the same base class (PackageReader) and all provide the following common functionality for operating on an e-learning package:
| Method Name | Description |
| CreateManifestNavigator | Loads the package manifest into memory and returns an XPathNavigator that refers to the root <manifest> node. (In the case of a Class Server LRM file, the file is internally converted to SCORM 1.2 format.) |
| FileExists | Determines if a given file exists in the package. |
| GetFileStream | Returns a read-only Stream onto a specified file within the package. |
| GetFilePaths | Enumerates the files in the package. |
MLC implements these package readers:
| Package Reader | Constructor Parameter(s) |
| FileSystemPackageReader | The path to a directory containing the contents of an unzipped package. |
| ZipPackageReader | The path to a .zip file containing SCORM or Class Server IMS+ content, or a Stream open onto such a .zip file. |
| LrmPackageReader | The path to a Class Server .lrm file, or a Stream open onto a .lrm file. |
| SharePointPackageReader | The location of a .zip (SCORM or Class Server IMS+) or Class Server .lrm file stored in a SharePoint document library. |
All these package readers except SharePointPackageReader are implemented in Microsoft.LearningComponents.dll, which does not depend on SQL Server or SharePoint. SharePointPackageReader, implemented in Microsoft.LearningComponents.SharePoint.dll, depends (of course) on SharePoint.
As an alternative to using the constructor of a package reader class, if you have a Stream containing a .zip or .lrm file you can use the static method PackageReader.Create, which automatically detects the type of package and creates and returns a ZipPackageReader or LrmPackageReader.
The MLC ManifestReader class helps an application navigate the manifest of an e-learning package. For SCORM packages, the manifest is a file named imsmanifest.xml in the root of the package. For Class Server LRM and IMS+ packages, the manifest is a dynamically-generated imsmanifest.xml, in SCORM 1.2 format, that contains information from the Index.xml file at the root of the package.
When ManifestReader encounters an error in the manifest, it provides the application with the following options for handling the error:
Programming tasks:
Given a SCORM package, PackageValidator verifies that the manifest is correct and verifies that the files referenced in the manifest are actually present in the package. (ManifestReader, described above, implicitly performs a certain level of manifest validation, but only on the parts of the manifest that the caller chooses to access.)
PackageValidator does not perform any validation of files other than the manifest file. For example, PackageValidator does not verify that images are correct, SCORM RTE JavaScript calls are present and correct, etc. The only validation performed on files other than the manifest file is whether or not files listed in the manifest are in fact present in the manifest.
PackageValidator can also validate a Class Server LRM or IMS+ package, but the validation is much more limited because the manifest that drives the validation process is the manifest that's automatically converted from the Class Server Index.xml file.
PackageValidator categorizes problems encountered in a package as follows:
For each category of problem listed above, PackageValidator allows the caller to decide what to do. The options are:
Programming tasks: